//
//  thirdViewController.m
//  UITabBarController
//
//  Created by 王恕 on 15/12/31.
//  Copyright © 2015年 王恕. All rights reserved.
//

#import "thirdViewController.h"

@interface thirdViewController ()

@property (nonatomic, strong) UIView *thirdView;

@end

@implementation thirdViewController
@synthesize thirdView;

- (id)init{
    if ([super init] != nil) {
        UITabBarItem *item = [[UITabBarItem alloc] initWithTabBarSystemItem:UITabBarSystemItemFavorites tag:1];
        item.badgeValue = @"3";
        self.tabBarItem = item;
        [self thirdView];
    }
    return self;
}

- (UIView *)thirdView{
    if (!thirdView) {
        thirdView = [[UIView alloc] initWithFrame:self.view.bounds];
        thirdView.backgroundColor = [UIColor blueColor];
        [self.view addSubview:thirdView];
    }
    return thirdView;
}


- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
